// 引入模块
let express = require("express")

let app = express();

let ejs = require("ejs")

app.set("view engine", "html")

app.set("views", __dirname + "/登录注册静态页面")

app.engine("html", ejs.__express);

// 获取静态数据
app.use(express.static(__dirname + "/登录注册静态页面/static"))


app.get("/log", (req, res) => { 
    res.render("login.html")
})
app.get("/reg", (req, res) => { 
    res.render("register.html")
})


//监听端口
app.listen(4000, "127.0.0.1", () => {
    console.log("启动")
})